import request from '@/utils/request'

// 费用项列表
export function feeItemList() {
  return request({
    url: '/charteredBus/feeItems/feeItemList',
    method: 'get'
  })
}


//包车方案list
export function list(query) {
    return request({
        url: '/charteredBus/priceSetting/list',
        method: 'get',
        params: query
    })
}

// 删除方案主
export function delCharteredBusPlan(planId) {
    return request({
        url: '/charteredBus/priceSetting/' + planId,
        method: 'delete'
    })
}

// 导出方案主
export function exportPlan(query) {
    return request({
        url: '/plan/plan/export',
        method: 'get',
        params: query
    })
}

export function getTenantConfig(query) {
    return request({
        url: '/plan/plan/getTenantConfig',
        method: 'get',
        params: query
    })
}

// 车型业务配置列表
export function configurationList(query) {
    return request({
        url: '/charteredBus/priceSetting/configurationList',
        method: 'get',
        params: query
    })
}

// 启停用
export function stopUsingEnabled(data) {
    return request({
        url: '/charteredBus/priceSetting/stopUsingEnabled',
        method: 'put',
        data: data
    })
}


export function insertCharteredBusPlan(data) {
    return request({
        url: '/charteredBus/priceSetting/insertCharteredBusPlan',
        method: 'post',
        data: data
    })
}

export function getInfo(charteredBusPlanId) {
    return request({
        url: '/charteredBus/priceSetting/getInfo/' + charteredBusPlanId,
        method: 'get',
    })
}

export function updateCharteredBusPlan(data) {
    return request({
        url: '/charteredBus/priceSetting/updatePlan',
        method: 'put',
        data: data
    })
}

export function updateDayAmountPlan(data) {
    return request({
        url: '/plan/plan/updateDayAmountPlan',
        method: 'put',
        data: data
    })
}

export function updatespecifiedAmountPlan(data) {
    return request({
        url: '/plan/plan/updatespecifiedAmountPlan',
        method: 'put',
        data: data
    })
}
